package com.ruoyi.project.system.service.impl;

import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.project.system.domain.SiyuUserPrice;
import com.ruoyi.project.system.mapper.SiyuUserPriceMapper;
import com.ruoyi.project.system.service.ISiyuUserPriceService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;

/**
 * 定制价格Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-10-28
 */
@Service
public class SiyuUserPriceServiceImpl implements ISiyuUserPriceService
{
    @Autowired
    private SiyuUserPriceMapper siyuUserPriceMapper;


    /**
     * 新增定制价格
     * 
     * @param siyuUserPrice 定制价格
     * @return 结果
     */
    @Override
    public int insertSiyuUserPrice(SiyuUserPrice siyuUserPrice)
    {
        siyuUserPrice.setCreateTime(DateUtils.getNowDate());
        return siyuUserPriceMapper.insertSiyuUserPrice(siyuUserPrice);
    }

    /**
     * 修改定制价格
     * 
     * @param siyuUserPrice 定制价格
     * @return 结果
     */
    @Override
    public int updateSiyuUserPrice(SiyuUserPrice siyuUserPrice)
    {
        siyuUserPrice.setUpdateTime(DateUtils.getNowDate());
        return siyuUserPriceMapper.updateSiyuUserPrice(siyuUserPrice);
    }

}
